1. Field of the Invention
The present invention relates to an image processing apparatus and a method therefor, for example an image processing apparatus and a method therefor, for effecting binarization by determining a binarizing threshold value for a multi-level image, and more particularly an image processing apparatus and a method therefor effecting division of image regions for a character recognition process in the image.
2. Related Background Art
The image processing technology has shown remarkable progress in recent years, and there has become popular the image processing apparatus capable of processing a multi-level image such as a full-color image and of character recognition in a multi-level image.
In such image processing technology, binarization of the multi-level image is an indispensable technology. For such binarization, there have conventionally known a simple binarizing method utilizing a predetermined fixed threshold value, an Otsu method employing a binarizing threshold value which maximizes the dispersion between two classes divided by this threshold value in the histogram (Otsu, "Automatic threshold selection based on judgment and minimum square method", Journal of Electronic Communication Society, vol. J63-D, No.4, pp.349-356, 1980) and a binarizing method for determining the threshold value for a tonal image, based on the local density.
However such binarizing methods in the conventional image processing apparatus have been associated with the following drawbacks.
In the simple binarizing method with the fixed threshold value, it is difficult to select a suitable threshold value between the density of the object and that of the background within an image, and, as a result, the entire image tends to become blackish or whitish. In the Otsu method, when the two classes have extremely different distributions, the threshold value tends to be deviated toward the higher class, so that a binary image with much noises is generated. Also the binarization method for determining the threshold value according to the local density tends to generate block distortion, as the image is divided into local regions.
With the recent progress in the image processing technology, images mixedly containing characters, photographs, graphs etc. are increasingly processed in the image processing apparatus such as computers. In such case, the image to be processed is at first read by an image input device such as a scanner and entered into the image processing apparatus, which effects, on the input image, a region dividing process for extracting the black pixel areas and an optical character recognition (OCR) process and document management to utilize thus obtained characters and images. The region dividing process is to divide and extract the black pixels in the image, thereby separating the areas of character/photograph/graph/table etc. in the image by the features thereof and obtaining the information of each area. Also the OCR process is to convert, in the character region in the image, the bit map constituting the character images into character codes.
In the following there will be explained, with reference to a flow chart in FIG. 26, the processing of an image containing a character, in the above-explained conventional image processing apparatus.
At first a step S221 enters an original image by an image processing device such as a scanner, in a form, for example, of multi-level image data of 8 bits. A next step S222 effects elimination of the electrical noise, generated in the scanner at the image input, and correction for the deterioration of the input original image and the inclination of the original image. Then a step S223 effects a region dividing process on the input image by the simple binarization with a fixed threshold value and extraction of the character region by releasing the data of each region. The above-mentioned simple binarization process can be, for example, a binarization process according to the density of the input image. Then a step S224 effects character recognition by a desired image processing such as an OCR process or a pseudo continuous tone process on each extracted character region. Then, a last step S225 displays the result of process, such as the recognized character.
In the conventional image processing apparatus, as explained in the foregoing, the input image is subjected to the simple binarizing process with the fixed threshold value or according to the density of the original image and to the region dividing process for extracting the text area in the image, for the purpose of character recognition.
Such conventional image processing apparatus has however been associated with the following drawbacks.
As an example, let us consider a case where the original image has a white background, on which characters are formed in black or gray color. Such original image contains three or more luminance levels, and, in the simple binarization with the fixed threshold value on such image, the gray character region is binarized as "white" in an area and as "black" in the other. As these two areas are generated irregularly, the gray characters become thicker and thinner, so that highly precise binarization cannot be achieved. Consequently the region dividing process and the character recognition process cannot be executed in exact manner, and significant deterioration is encountered in the division of the gray character region and the character recognition rate of the gray characters.
Also in the simple binarization process according to the original image density, as the background is not purely "white", the binarization process results in a classification of the background as "white" and the black and gray characters as "black", or of the background and the gray characters as "white" and the black characters as "black". Thus the gray characters cannot be binarized precisely also in this case, so that the regional division and the character recognition cannot be achieved in exact manner.
Also, even if the gray character region and the gray characters can be recognized, they cannot be distinguished from the black character region and the black characters.